<template>
	<view>
		<view class="uni-tab-bar">
			<scroll-view class="uni-swiper-tab" scroll-x="true">
				<block v-for="(item,index) in tablist" :key="index">
					<view class="swiper-tab-list" :class="{active:ppp==index}" 
					@tap="touch(index)"
					>{{item.name}}</view>
				</block>
			</scroll-view>
		</view>
	</view>
</template>

<script>
	export default {
		props:{
			tablist:Array,
			ppp:Number
		},
		data() {
			return {
			};
		},
		methods:{
			touch(index)
			{
				this.$emit("upp",index)
			}
		}
	}
</script>

<style lang="less">
.uni-tab-bar .active {
	font-size: 36rpx;
}
</style>
